import request from '@/static/js/utils/request'
import { envConfig } from '@/static/js/env/env'
const { baseUrl } = envConfig

// 获取订单列表
export function getOrderList(data) {
    return request.get({
        url: `${baseUrl}/api/front/order/list`,
        data
    })
}

// 预下单
export function createBeforeOrder(data) {
    return request.post({
        url: `${baseUrl}/api/front/order/pre/order`,
        data
    })
}

// 加载预下单
export function getCreatePreOrderDetail(data) {
    return request.get({
        url: `${baseUrl}/api/front/order/load/pre/${data.preOrderNo}`,
        data
    })
}
